Optimal. Leaf size=31 \[ \frac {1}{2} (a+2 b) x+\frac {a \cos (e+f x) \sin (e+f x)}{2 f} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.02, antiderivative size = 31, normalized size of antiderivative = 1.00, number of steps
used = 2, number of rules used = 2, integrand size = 21, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.095, Rules used = {4130, 8}
\begin {gather*} \frac {1}{2} x (a+2 b)+\frac {a \sin (e+f x) \cos (e+f x)}{2 f} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 8
Rule 4130
Rubi steps
\begin {align*} \int \cos ^2(e+f x) \left (a+b \sec ^2(e+f x)\right ) \, dx &=\frac {a \cos (e+f x) \sin (e+f x)}{2 f}+\frac {1}{2} (a+2 b) \int 1 \, dx\\ &=\frac {1}{2} (a+2 b) x+\frac {a \cos (e+f x) \sin (e+f x)}{2 f}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.04, size = 33, normalized size = 1.06 \begin {gather*} b x+\frac {a (e+f x)}{2 f}+\frac {a \sin (2 (e+f x))}{4 f} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 0.06, size = 37, normalized size = 1.19
method | result | size |
risch | \(\frac {a x}{2}+x b +\frac {a \sin \left (2 f x +2 e \right )}{4 f}\) | \(24\) |
derivativedivides | \(\frac {a \left (\frac {\sin \left (f x +e \right ) \cos \left (f x +e \right )}{2}+\frac {f x}{2}+\frac {e}{2}\right )+b \left (f x +e \right )}{f}\) | \(37\) |
default | \(\frac {a \left (\frac {\sin \left (f x +e \right ) \cos \left (f x +e \right )}{2}+\frac {f x}{2}+\frac {e}{2}\right )+b \left (f x +e \right )}{f}\) | \(37\) |
norman | \(\frac {\left (-\frac {a}{2}-b \right ) x +\left (-\frac {a}{2}-b \right ) x \left (\tan ^{2}\left (\frac {f x}{2}+\frac {e}{2}\right )\right )+\left (\frac {a}{2}+b \right ) x \left (\tan ^{4}\left (\frac {f x}{2}+\frac {e}{2}\right )\right )+\left (\frac {a}{2}+b \right ) x \left (\tan ^{6}\left (\frac {f x}{2}+\frac {e}{2}\right )\right )-\frac {a \tan \left (\frac {f x}{2}+\frac {e}{2}\right )}{f}+\frac {2 a \left (\tan ^{3}\left (\frac {f x}{2}+\frac {e}{2}\right )\right )}{f}-\frac {a \left (\tan ^{5}\left (\frac {f x}{2}+\frac {e}{2}\right )\right )}{f}}{\left (1+\tan ^{2}\left (\frac {f x}{2}+\frac {e}{2}\right )\right )^{2} \left (\tan ^{2}\left (\frac {f x}{2}+\frac {e}{2}\right )-1\right )}\) | \(147\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A]
time = 0.48, size = 40, normalized size = 1.29 \begin {gather*} \frac {{\left (f x + e\right )} {\left (a + 2 \, b\right )} + \frac {a \tan \left (f x + e\right )}{\tan \left (f x + e\right )^{2} + 1}}{2 \, f} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 1.95, size = 30, normalized size = 0.97 \begin {gather*} \frac {{\left (a + 2 \, b\right )} f x + a \cos \left (f x + e\right ) \sin \left (f x + e\right )}{2 \, f} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [A]
time = 3.45, size = 51, normalized size = 1.65 \begin {gather*} a \left (\begin {cases} \frac {x \sin ^{2}{\left (e + f x \right )}}{2} + \frac {x \cos ^{2}{\left (e + f x \right )}}{2} + \frac {\sin {\left (e + f x \right )} \cos {\left (e + f x \right )}}{2 f} & \text {for}\: f \neq 0 \\x \cos ^{2}{\left (e \right )} & \text {otherwise} \end {cases}\right ) + b x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A]
time = 0.42, size = 37, normalized size = 1.19 \begin {gather*} \frac {{\left (f x + e\right )} {\left (a + 2 \, b\right )} + \frac {a \tan \left (f x + e\right )}{\tan \left (f x + e\right )^{2} + 1}}{2 \, f} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 4.31, size = 25, normalized size = 0.81 \begin {gather*} \frac {\frac {a\,\sin \left (2\,e+2\,f\,x\right )}{4}+f\,x\,\left (\frac {a}{2}+b\right )}{f} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________